﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using ToolwebAQ.database;
using System.Data.SqlClient;
using System.Data;

namespace ToolwebAQ.adminaq
{
    public partial class AQListEmployee : System.Web.UI.Page
    {
        int mid;

        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void Page_Init(object sender, EventArgs e)
        {
            BindEmployee();
        }

        private void BindEmployee()
        {
            using (aquariusDBDataContext db = new aquariusDBDataContext())
            {
                var listemp = from list in db.Tbl_Project_employees select list;
                SqlCommand cmd = (SqlCommand)db.GetCommand(listemp);
                DataSet ds = new DataSet();
                SqlDataAdapter da = new SqlDataAdapter(cmd);
                da.Fill(ds);
                gvListEmployee.DataSource = ds;
                gvListEmployee.DataBind();
            }
        }
    }
}